package main

import (
	"fmt"
	"github.com/cy77cc/hioshop/global"
	"github.com/cy77cc/hioshop/initialize"
	"log"
)

// @title hioshop
// @version 1.0
// @description 测试
// @termsOfService http://swagger.io/terms/

// @contact.name cy77cc
// @contact.url http://www.swagger.io/support
// @contact.email support@swagger.io

// @license.name Apache 2.0
// @license.url http://www.apache.org/licenses/LICENSE-2.0.html

// @host 8080
// @BasePath /api/v1
func main() {
	global.VP = initialize.Viper("config.yaml")
	fmt.Println(global.CONFIG)
	engine := initialize.InitApp()
	err := engine.Run(":" + global.CONFIG.System.Port)

	if err != nil {
		log.Panicln("项目启动失败：", err.Error())
	}
}
